package code07_面向对象.封装;

/**
 * @author 黄衡熙
 * @version 1.0
 * @date 2025年07月21日19:00
 */
public class Test {
    public static void main(String[] args) {
        User user = new User();
//        user.id = 1;
//        System.out.println(user.username);
        user.setId(1);
        user.setUsername("admin");
        user.setPassword("123456");
        user.setPhone("13812345678");
        user.setAddress("江苏-南京");
        user.setStatus(true);

        System.out.println(user.getId());
        System.out.println(user.getUsername());
        System.out.println(user.getPassword());
        System.out.println(user.getPhone());
        System.out.println(user.getAddress());
        System.out.println(user.getStatus());
        System.out.println(user.isStatus());
        System.out.println("************************************");
        User user2 = new User(1, "jack", "111111", "13112369876", "江苏-苏州", false);
        System.out.println(user2.getId());
        System.out.println(user2.getUsername());
        System.out.println(user2.getPassword());
        System.out.println(user2.getPhone());
        System.out.println(user2.getAddress());
        System.out.println(user2.isStatus());
    }
}
